<?php

$name = "";
if(isset($params["name"])){
	$name = $params["name"];
}
$id = "";
if(isset($params["id"])){
	$id = $params["id"];
}
$text = "";
if(isset($params["text"])){
	$text = $params["text"];
}

$checked = false;
if(isset($params["checked"])){
	$checked = $params["checked"];
}

$onclick = "";
if(isset($params["onclick"])){
	$onclick = $params["onclick"];
}

?>
 
<?php
echo "<input type='checkbox' "; 

if ($name != "") echo " name='" . $name ."' ";
if ($id != "") echo " id='" . $id ."' ";
if ($checked != "") echo " checked";
if ($onclick != "") echo " onclick='$onclick'";
echo " >";
if ($text != "") echo $text;

echo "</input>";
?>